package com.och.mrcp.model;

import lombok.Data;

/**
 * 语音识别结果
 */
@Data
public class RecognitionResult {

    private String taskId;
    private String text = "";
    private double confidence = 0.0;
    private Integer beginTime = 0;
    private long duration = 0; // 音频时长（毫秒）
    private String language = "zh-CN";
    private boolean isFinal = false;
    private long timestamp = System.currentTimeMillis();
    
    public RecognitionResult() {}
    
    public RecognitionResult(String text, double confidence, long duration, String language, boolean isFinal) {
        this.text = text;
        this.confidence = confidence;
        this.duration = duration;
        this.language = language;
        this.isFinal = isFinal;
    }
}
